package com.sp2.dev.test.listener.day0211;

import java.util.ArrayList;
import java.util.List;

/**
 * Created by IntelliJ IDEA.
 * User: zhimingli
 * Date: 14-2-11
 * Time: 上午9:32
 * To change this template use File | Settings | File Templates.
 */
public class Mubiao {

    private List<Guancha> list = new ArrayList<Guancha>();

    public void add(Guancha guancha) {
        list.add(guancha);
    }

    public void noifyOther(Guancha guancha) {
        for (Guancha em : list) {
            if (!em.getEmployees().getName().equalsIgnoreCase(guancha.getEmployees().getName())) {
                GuanchaImpl impl = (GuanchaImpl) guancha;
                impl.setMessage();
            }
        }
    }

}
